import { _decorator, Component, Node } from 'cc';
const { ccclass, property } = _decorator;

@ccclass('RotateForever')
export class RotateForever extends Component {
    @property(Node)
    target: Node = null
    @property
    speed = 100

    start() {

    }

    update(deltaTime: number) {
        const target = this.target || this.node
        target.angle -= this.speed * deltaTime
    }
}

